﻿@{
    Layout = null;
}

<!DOCTYPE html>

<html>
<head>
    <meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=1.0, user-scalable=0">

    <title></title>
    <script src="~/Content/Script/jquery.min.js"></script>
    <script src="~/Scripts/base64.js"></script>
    <style>
        .isNoPublic {
            height: 1.4rem;
            width: 11.25rem;
            margin: 0 auto;
            font-size: .7rem;
            color: #fff;
            text-align: center;
            line-height: 1.4rem;
            position: absolute;
            left: 0;
            top: 0;
            z-index: 9999;
             background: url(https://shnbbucket.oss-cn-beijing.aliyuncs.com/20180315233216.png) no-repeat;
            background-size: 100%;
        }
        * {
            padding: 0;
            margin: 0;
            cursor: pointer;
        }

        .award-details, body {
            width: 100%;
            height: 100%;
            background: #f2f2f2;
            position:absolute;
        }

        #LoadingBar {
            position: absolute;
            background-color: rgba(0,0,0,.85);
            width: 100%;
            height: 100%;
            display: flex;
            align-items: center;
            justify-content: center;
            z-index: 999;
        }

        .OneKeyAttention {
            width: 100%;
            height: 100%;
            position: absolute;
            background-color: rgba(0,0,0,.85);
            z-index: 555;
            display: none;
        }


            .OneKeyAttention .Attention-con {
                width: 80%;
                left: 10%;
                top: 10%;
                height: 65%;
                position: absolute;
                background-color: white;
                z-index: 556;
                border-radius: 4px;
                display: flex;
                align-items: center;
                justify-content: space-around;
                flex-direction: column;
            }

                .OneKeyAttention .Attention-con > img:nth-child(1) {
                    width: 60%;
                    margin: 0 auto;
                    display: block;
                }

                .OneKeyAttention .Attention-con > img:nth-child(2) {
                    width: 36%;
                    margin: 0 auto;
                    display: block;
                }
                  .closeBgCon {
            position: absolute;
            width: 100%;
            height: 50px;
            bottom: 3%;
            display: flex;
            justify-content: center;
            align-items: center;
            cursor: pointer;
        }

      .closeBgCon img {
            width: 50px;
            height: 100%;
            cursor: pointer;
        }

        .award-details .award-head {
            text-align: center;
            color: white;
            padding: 10px 0;
        }

            .award-details .award-head p:nth-child(1) {
                text-align: left;
            }

        .award-details .award-body {
            background: white;
            text-align: center;
            padding: 10px 0;
            color: gray;
        }

        .award-details .award-details-list {
            display: none;
            align-items: center;
            padding: 10px;
            border-bottom: solid 1px #E0E0E0;
            background: white;
        }

            .award-details .award-details-list span:nth-child(1) {
                margin-left: 5px;
            }

            .award-details .award-details-list span:nth-child(2) {
                margin-right: 5px;
                margin-left: 5px;
            }

            .award-details .award-details-list span:nth-child(3) {
                margin-right: 5px;
            }
        a {
            text-decoration: none;
             
        }
    </style>

</head>
<body id="content">
    <div class="isNoPublic">
        活动尚未发布，当前仅供预览！
    </div>
  

</body>
</html>

<script>
    //活动详情 关注我们
    function AwAttention() {

        $('.OneKeyAttention').css('display', 'block')
    }
    function OneKeyAttention(ele, event) {
        $(ele).css('display', 'none');
        event.stopPropagation();
    }
    function Attention(event) {
        event.stopPropagation();
    }
    var tid = "@ViewBag.Tid";//模板Id
    $.ajax({
        url: "PrizeDetailsShowHtml",
        data: { Tid: tid },
        type: "post",
        success: function (res) {
            $("#content").html(decode(res));
            $('#content .pageTitle').remove();
            getAwardInfo();
        }
    });
    //关闭微信页面

    function closePage() {
        WeixinJSBridge.call('closeWindow');
    }


    function DateFormat(val) {
        var date = new Date(parseInt(val.replace("/Date(", "").replace(")/", ""), 10));
        //月份为0-11，所以+1，月份小于10时补个0
        var month = date.getMonth() + 1 < 10 ? "0" + (date.getMonth() + 1) : date.getMonth() + 1;
        var currentDate = date.getDate() < 10 ? "0" + date.getDate() : date.getDate();
        var currentHour = date.getHours();
        var currentMin = date.getMinutes();
        var currentSecond = date.getSeconds();
        var dd = date.getFullYear() + "-" + month + "-" + currentDate
        return dd;
    }
    function GetQueryString(name) {
        var reg = new RegExp("(^|&)" + name + "=([^&]*)(&|$)");
        var r = window.location.search.substr(1).match(reg);
        if (r != null) return unescape(r[2]);
        return null;
    }

    //获取我的中奖记录数据
        function getAwardInfo() {
            var eName="@ViewBag.eName";
            var Denomination = "@ViewBag.Denomination";
            var time = "@ViewBag.Time";
            $('#EnterpriseName').text(eName || 'lak').next().text('微信红包' + parseFloat(Denomination).toFixed(2) + '元').next().text('您已于' + time + '领取了红包');
            $('#handleTips').text(res.AwCongrats||'红包已存入您的零钱').prev().text('活动码:' + res.JiaMiCode);
                    function initPage() {
                        var objLoading = document.getElementById("LoadingBar");
                        if (objLoading != null) {
                            objLoading.style.display = "none";
                        }
                    }
                    initPage();
        }



</script>
